﻿//
/// <reference path="../../../jquery-2.1.0.js" />
/// <reference path="../../../jasime/jasmine.js" />
/// <reference path="../../../jasime/jasmine-jquery.js" />
/// <reference path="../../../angular.js" />
/// <reference path="../../../angular-mocks.js" />
/// <reference path="../../../angular-bootstrap.js" />
/// <reference path="../../../angular-resource.js" />
/// <reference path="../../../angular-mocks.js" />
/// <reference path="../../../ui-bootstrap-0.7.0.js" />
/// <reference path="../../../angular-cookies.js" /> 
/// <reference path="../../../toastr.js" />
/// <reference path="../../../ui.select2.js" />
/// <reference path="../../../ngStorage.js" />
/// <reference path="../../../ngRoute.js" />
/// <reference path="../../../geocoder.js" />
/// <reference path="../../../underscore.js" />
/// <reference path="../../../angular-underscore.js" />
/// <reference path="../../../datepicker.js" />


/// <reference path="../../../app/app.js" />
/// <reference path="../../../app/directives.js" />
/// <reference path="../../../app/filters.js" />
/// <reference path="../../../app/services.js" />
/// <reference path="../../../app/controllers.js" />

// test/unit/services/ServiceSpec.js


describe("Unit: Testing Controllers", function () {

//Mocks
    var windowMock, httpBackend, myService, sharedMock;
    //Mock for $window service
    windowMock = { location: { href: "" } };

var mod = angular.module('app.services', ['ngResource'])
var AdminServicesMock = { GetByDesc: function () { return null } };
beforeEach(function () {
   // var mod = angular.module('app.services', ['ngResource'])
  //  module('mod');
    inject(function ($injector) {
        resource = $injector.get('$resource');
        $httpBackend = $injector.get('$httpBackend');
        AdminServicesMock = $injector.get('AdminServices');

    })
});

//afterEach(function () {
//    $httpBackend.verifyNoOutstandingExpectation();
//    $httpBackend.verifyNoOutstandingRequest();
//});


    it('should contain an AdminServices service', inject(function (AdminServicesMock) {
        expect(AdminServicesMock).not.toBeUndefined();

    }));


    it("Should call GetByDesc function on call", function () {

        expect(AdminServicesMock.GetByDesc("id = gender")).toHaveBeenCalled();

    });


});

     